
/*
 *    MCreator note: This file will be REGENERATED on each build.
 */
package net.minecrea.electric.init;

import net.minecrea.electric.block.MachineWorldPortalBlock;
import net.minecrea.electric.block.ElectricWaterBlock;
import net.minecrea.electric.block.ElectricOreBlock;
import net.minecrea.electric.block.ElectricBlockBlock;
import net.minecrea.electric.ElectricMod;

import net.minecraftforge.registries.RegistryObject;
import net.minecraftforge.registries.ForgeRegistries;
import net.minecraftforge.registries.DeferredRegister;
import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.api.distmarker.Dist;

import net.minecraft.world.level.block.Block;

public class ElectricModBlocks {
	public static final DeferredRegister<Block> REGISTRY = DeferredRegister.create(ForgeRegistries.BLOCKS, ElectricMod.MODID);
	public static final RegistryObject<Block> ELECTRIC_BLOCK = REGISTRY.register("electric_block", () -> new ElectricBlockBlock());
	public static final RegistryObject<Block> ELECTRIC_ORE = REGISTRY.register("electric_ore", () -> new ElectricOreBlock());
	public static final RegistryObject<Block> ELECTRIC_WATER = REGISTRY.register("electric_water", () -> new ElectricWaterBlock());
	public static final RegistryObject<Block> MACHINE_WORLD_PORTAL = REGISTRY.register("machine_world_portal", () -> new MachineWorldPortalBlock());

	@Mod.EventBusSubscriber(bus = Mod.EventBusSubscriber.Bus.MOD, value = Dist.CLIENT)
	public static class ClientSideHandler {
		@SubscribeEvent
		public static void clientSetup(FMLClientSetupEvent event) {
			ElectricBlockBlock.registerRenderLayer();
		}
	}
}
